@layout("/common/_container.html"){
<div class="ibox float-e-margins">
    <div class="ibox-content">
        <div class="form-horizontal">

            <input type="hidden" id="id" value="${item.id}">

            <div class="row">
                <div class="col-sm-6 b-r">
                    <#input id="id" name="房间ID" value="${item.id}"  underline="true" disabled = "true"/>
                    <#input id="name" name="房间名称" value="${item.name}" underline="true"/>
                    <#input id="buildCode" name="房间编码" value="${item.buildCode}" underline="true"/>
                </div>

                <div class="col-sm-6">
                    <!-- <#input id="roomType" name="房间户型" value="${item.roomType}" underline="true"/>-->
                    <!--<#input id="roomImage" name="房间图片" value="${item.roomImage}" underline="true"/>-->
                    <input id="toState" type="text" value="${isRent}" style="display: none;">
                    <div class="form-group">
                        <div class="form-horizontal" style="overflow: hidden; flex:1;">
                            <div class="col-lg-9" style=" display: flex; justify-content: center; align-items: center;">
                                <label class="col-sm-3 control-label" style="margin-left: -14px;">房屋状态</label>
                                <div class="col-sm-9">
                                    <select class="form-control" onchange="selectOnchange(this)" id="isRent"
                                            style="width: 247px;">
                                        <option value="1">已出租</option>
                                        <option value="0">未出租</option>
                                    </select>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="hr-line-dashed"></div>
                    <#input id="roomArea" name="房间面积" value="${item.roomArea}" underline="true"/>
                    <div class="form-group">
                        <label class="col-sm-3 control-label">起租日期</label>
                        <div class="col-sm-9">
                            <input type="date" class="form-control" id="date" name="${item.startDate}"/>
                        </div>
                    </div>
                </div>

            </div>
            <div class="table-responsive" id="table">
                <table class="table table-bordered" style="text-align: center;margin-bottom: 0;">
                    <thead>
                    <tr>
                        <th></th>
                        <th>费用名称</th>
                        <th>单价</th>
                        <th>计价方式</th>
                        <th>计量单位</th>
                        <th>操作</th>
                    </tr>
                    </thead>
                    <tbody id="abc">
                    @for(list in roomExpenseList){
                    <tr id="${list.id}">
                        <td>
                            <input id="radio" type="radio" name="optionsRadiosinline" id="optionsRadios3"
                                   value="option1"/>
                        </td>
                        <td class="editName">${list.name}</td>
                        <td class="editPrice">${list.price}</td>
                        <td class="editUnit">${list.unit}</td>
                        <td value="${list.valuationType}" class="editValuation">${list.valuationType}</td>
                        <td>
                            <a id="btn" href="javascript:;">修改</a>
                            <a class="delBtn" href="javascript:;">删除</a>
                        </td>
                    </tr>
                    @}
                    </tbody>
                </table>
                <div class="hidden-xs" id="addexpense" role="group" style=" width: 200px; margin: 10px auto;">
                    <#button name="增加费用" id="addExpense" icon="fa-plus" />
                </div>
            </div>
            <div id="money" style="display: none; margin-bottom: 30px;position: relative;">
                <div class="page-header1" style="border: 0; overflow: hidden;display: flex; flex: 1;">
                    <div class="form-horizontal" style="display: flex; overflow: hidden; flex:1;">
                        <div class="col-lg-9" style=" display: flex; justify-content: center; align-items: center;">
                            <strong style="width: 92px; margin-right: 20px; margin-left: 28px;">费用名称</strong>
                            <select class="form-control" onchange="selectOnchange1(this)" id="expenses">
                                <option>月租</option>
                                <option>押金</option>
                                <option>水费</option>
                                <option>电费</option>
                                <option>维修费</option>
                                <option>已收款</option>
                                <option>未收款</option>
                            </select>
                        </div>
                        <div id="application" style=" display: none;">
                            用途：<input id="use" type="text" style="width: 150px; margin-top: 5px;"/>
                        </div>
                    </div>
                    <div class="col-sm-6" style="overflow: hidden; margin-left: 50px;flex: 1;margin-top: 20px;">
                        <#input id="price" name="单价"/>
                    </div>
                </div>
                <div class="page-header1"
                     style="border: 0; overflow: hidden;display: flex; flex: 1; margin-bottom: 10px; ">
                    <div class="form-horizontal" style="overflow: hidden; flex:1;">
                        <div class="col-lg-9" style=" display: flex; justify-content: center; align-items: center;">
                            <strong style="width: 98px; margin-right: 20px; margin-left: 28px;">计量单位</strong>
                            <select class="form-control" onchange="selectOnchange3(this)" id="valuationType">

                            </select>
                        </div>
                    </div>
                    <div class="form-horizontal" style="overflow: hidden; flex:1;">
                        <div class="col-lg-9" style=" display: flex; justify-content: center; align-items: center;">
                            <strong style="width: 285px; margin-right: 30px; text-align: right;">计价方式</strong>
                            <select class="form-control" onchange="selectOnchange2(this)" id="unit">
                                <option>元/月</option>
                                <option>元</option>
                            </select>
                        </div>
                    </div>
                </div>
                <div class="hidden-xs" id="RoomTableToolbar" role="group" style=" width: 200px; margin: auto;">
                    <#button name="修改清单" id="editExpense" icon="fa-plus" />
                </div>
                <div id="off" style="position: absolute; top: 3px; right: 6px;cursor: pointer;">X</div>
            </div>
            <div id="addMoney" style="display: block; margin-bottom: 30px; position: relative; display: none;">
                <div class="page-header1" style="border: 0; overflow: hidden;display: flex; flex: 1;">
                    <div class="form-horizontal" style="display: flex; overflow: hidden; flex:1;">
                        <div class="col-lg-9" style=" display: flex; justify-content: center; align-items: center;">
                            <strong style="width: 92px; margin-right: 20px; margin-left: 28px;">费用名称</strong>
                            <select class="form-control" onchange="selectOnchange1(this)" id="addName">
                                <option>月租</option>
                                <option>押金</option>
                                <option>水费</option>
                                <option>电费</option>
                                <option>维修费</option>
                                <option>已收款</option>
                                <option>未收款</option>
                            </select>
                        </div>
                        <div id="addApplication" style=" display: none;">
                            用途：<input id="addUse" type="text" style="width: 150px; margin-top: 5px;">
                        </div>
                    </div>
                    <div class="col-sm-6" style="overflow: hidden; margin-left: 50px;flex: 1;margin-top: 20px;">
                        <div class="form-group">
                            <label class="col-sm-3 control-label">单价</label>
                            <div class="col-sm-9">
                                <input class="form-control" id="addPrice" name="price" type="text">

                            </div>
                        </div>


                    </div>
                </div>
                <div class="page-header1"
                     style="border: 0; overflow: hidden;display: flex; flex: 1; margin-bottom: 10px; ">
                    <div class="form-horizontal" style="overflow: hidden; flex:1;">
                        <div class="col-lg-9" style=" display: flex; justify-content: center; align-items: center;">
                            <strong style="width: 98px; margin-right: 20px; margin-left: 28px;">计量单位</strong>
                            <select class="form-control" onchange="selectOnchange3(this)" id="addValuationType">
                            </select>
                        </div>
                    </div>
                    <div class="form-horizontal" style="overflow: hidden; flex:1;">
                        <div class="col-lg-9" style=" display: flex; justify-content: center; align-items: center;">
                            <strong style="width: 285px; margin-right: 30px; text-align: right;">计价方式</strong>
                            <select class="form-control" onchange="selectOnchange2(this)" id="addUnit">
                                <option selected="selected">元/月</option>
                                <option>元</option>
                            </select>
                        </div>
                    </div>
                </div>
                <div class="hidden-xs" id="addRoomTableToolbar" role="group" style=" width: 200px; margin: auto;">

                    <button type="button" class="btn btn-primary " onclick="" id="add">
                        <i class="fa fa-plus"></i>&nbsp;增加
                    </button>

                </div>
                <div id="addOff" style="position: absolute; top: 3px; right: 6px;cursor: pointer;">X</div>
            </div>
            <div class="table-propertyEdit" id="propertyTable">
                <table class="table table-bordered" style="text-align: center;margin-bottom: 0;">
                    <thead>
                    <tr>
                        <th></th>
                        <th>财产名称</th>
                        <th>数量</th>
                        <th>操作</th>
                    </tr>
                    </thead>
                    <tbody id="propertyBox">
                    @for(pList in propertyList){
                    <tr id = "${pList.id}">
                        <td>
                            <input id="pRadio" type="radio" name="optionsRadiosinline" value="option1"/>
                        </td>
                        <td class="editPname">${pList.name}</td>
                        <td class="editPprice">${pList.number}</td>
                        <td>
                            <a id="pBtn" href="javascript:;">修改</a>
                            <a class="delBtn" href="javascript:;">删除</a>
                        </td>
                    </tr>
                    @}
                    </tbody>
                </table>
                <div class="hidden-xs" id="addProperty" role="group" style=" width: 200px; margin: 10px auto;">
                    <#button name="增加资产" id="addpropertyBtn" icon="fa-plus" />
                </div>
            </div>
            <div id="propertyList" style='margin-top: 50px; display: none;position: relative'>
                <div id="propertyBox_edit" class="page-header1"  style="border: 0; overflow: hidden;display: flex; flex: 1; margin-bottom: 10px; ">
                    <div class="form-horizontal" style="overflow: hidden; flex:1;">
                        <div class="col-lg-9" style=" display: flex; justify-content: center; align-items: center; margin-top: 20px;">
                            <strong style="width: 98px; margin-right: 20px; margin-left: 28px;">财产名称</strong>
                            <select class="form-control" onchange="selectOnchanges(this)" id="property">

                            </select>
                        </div>
                    </div>
                    <div class="col-sm-6" style="overflow: hidden; margin-left: 50px;flex: 1;margin-top: 20px;">
                        <#input id="propertyNum" name="数量"/>
                    </div>
                </div>
                <div class="hidden-xs" id="RoomTablepropety" role="group" style=" width: 200px; margin: auto;">
                    <#button name="添加" id="newAddProperty" icon="fa-plus" />
                </div>
                <div id="addPoff" style="position: absolute; top: 3px; right: 6px;cursor: pointer;">X</div>
            </div>
            <div id="propertyListedit" style='margin-top: 50px; display: none; position: relative;'>
                <div class="page-header1"  style="border: 0; overflow: hidden;display: flex; flex: 1; margin-bottom: 10px; ">
                    <div class="form-horizontal" style="overflow: hidden; flex:1;">
                        <div class="col-lg-9" style=" display: flex; justify-content: center; align-items: center; margin-top: 20px;">
                            <strong style="width: 98px; margin-right: 20px; margin-left: 28px;">财产名称</strong>
                            <select class="form-control" onchange="editSelectOnchange(this)" id="propertyEdit">

                            </select>
                        </div>
                    </div>
                    <div class="col-sm-6" style="overflow: hidden; margin-left: 50px;flex: 1;margin-top: 20px;">
                        <#input id="editpropertyNum" name="数量"/>
                    </div>
                </div>
                <div class="hidden-xs" id="editProperty" role="group" style=" width: 200px; margin: auto;">
                    <#button name="修改" id="newEditProperty" icon="fa-plus" />
                </div>
                <div id="editOff" style="position: absolute; top: 3px; right: 6px;cursor: pointer;">X</div>
            </div>
            <div class="row btn-group-m-t">
                <div class="col-sm-10">
                    <#button btnCss="info" name="提交" id="ensure" icon="fa-check" clickFun="RoomInfoDlg.editSubmit()"/>
                    <#button btnCss="danger" name="取消" id="cancel" icon="fa-eraser" clickFun="RoomInfoDlg.close()"/>
                </div>
            </div>
        </div>

    </div>
</div>
<div class = "popup">
    <p>
        <span style = "color: #ffdf0c;" class = "iconfont icon-jinggao"></span>
        <span>请输入资产数量!</span>
    </p>
</div>
<script src="${ctxPath}/static/modular/system/room/room_edit_info.js"></script>
<!--<script src="${ctxPath}/static/modular/system/room/room.js"></script>-->

@}
